package mockup;

import java.util.ArrayList;

/**
 * An implementation of Event to hold information about a meeting.
 * @author Erik
 *
 */
public class MeetingMockup extends AppointmentMockup {

	private ArrayList<Integer> participants;
	
	public MeetingMockup(int id, String title, String description, 
			String location, int ownerID, ReservationMockup reservation, ArrayList<Integer> participants) {
		super(id, title, description, location, ownerID, reservation);
		
		if(participants == null) {
			this.participants = new ArrayList<Integer>();
		} else {
			this.participants = participants;
		}
	}

	/**
	 * Add a participant to this meeting.
	 * @param user The user to add
	 */
	public void addParticipant(int user) {
		participants.add(user);
	}
	
	/**
	 * Remove a participant from this meeting.
	 * @param user The user to remove
	 */
	public void removeParticipant(int user) {
		participants.remove(user);
	}

	public ArrayList<Integer> getParticipants() {
		return participants;
	}

	public void setParticipants(ArrayList<Integer> participants) {
		this.participants = participants;
	}
}
